/*
 * LeveyTabBarController
 * @description 本文件提供本app使用的定制的TabBarController文件
 * @package
 * @author 		***
 * @copyright
 * @version 		1.0
 * @description 本文件提供本app使用的定制的TabBarController文件
 */

#import <UIKit/UIKit.h>

@class  CustomStatueBar;

#import "LeveyTabBar.h"
@class UITabBarController;
@protocol LeveyTabBarControllerDelegate;
@interface LeveyTabBarController : UIViewController <LeveyTabBarDelegate>
{
	LeveyTabBar *_tabBar;
//	UIView      *_containerView;
//	UIView		*_transitionView;
	id<LeveyTabBarControllerDelegate> _delegate;
	NSMutableArray *_viewControllers;
	NSUInteger _selectedIndex;
	
	BOOL _tabBarTransparent;
	BOOL _tabBarHidden;
    
}

@property (retain, nonatomic  ) CustomStatueBar  *statueBar;//自定义状态栏

@property (nonatomic, copy    ) NSMutableArray   *viewControllers;
@property (nonatomic, retain  ) UIView           *containerView;
@property (nonatomic, retain  ) UIView           *transitionView;
@property (nonatomic, readonly) UIViewController *selectedViewController;
@property (nonatomic          ) NSUInteger       selectedIndex;
@property (nonatomic          ) BOOL             isFirstIn;

// Apple is readonly
@property (nonatomic, readonly) LeveyTabBar *tabBar;
@property(nonatomic,assign) id<LeveyTabBarControllerDelegate> delegate;


// Default is NO, if set to YES, content will under tabbar
@property (nonatomic) BOOL tabBarTransparent;
@property (nonatomic) BOOL tabBarHidden;

- (id)initWithViewControllers:(NSArray *)vcs imageArray:(NSArray *)arr;

- (void)hidesTabBar:(BOOL)yesOrNO animated:(BOOL)animated;

// Remove the viewcontroller at index of viewControllers.
- (void)removeViewControllerAtIndex:(NSUInteger)index;

// Insert an viewcontroller at index of viewControllers.
- (void)insertViewController:(UIViewController *)vc withImageDic:(NSDictionary *)dict atIndex:(NSUInteger)index;



@end


@protocol LeveyTabBarControllerDelegate <NSObject>
@optional
- (BOOL)tabBarController:(LeveyTabBarController *)tabBarController shouldSelectViewController:(UIViewController *)viewController;
- (void)tabBarController:(LeveyTabBarController *)tabBarController didSelectViewController:(UIViewController *)viewController;
@end

@interface UIViewController (LeveyTabBarControllerSupport)
@property(nonatomic, retain, readonly) LeveyTabBarController *leveyTabBarController;
@end

